import request from "@/request/index.js";

const auth = "auth"; //http://101.42.107.47:30019文档
const base = "base"; //http://101.42.107.47:30020文档
const zhpt = "zhpt"; //http://101.42.107.47:30018文档

//获取需求列表
export const getDemandListApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/console/search`,
        method: "post",
        data,
    });
};

//新增技术需求
export const addDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/publish`,
        method: "post",
        data,
    });
};

//新增科技服务需求
export const addScienceDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/science/publish`,
        method: "post",
        data,
    });
};

//删除禁用启用
export const operateDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/batch`,
        method: "post",
        data,
    });
};



//详情
export const demandDetailApi = (params) => {
    return request({
        url: `/api/${zhpt}/demand/console/search/info`,
        method: "get",
        params,
    });
};


//审核
export const auditDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/audit`,
        method: "post",
        data,
    });
};

//修改技术需求
export const editDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/edit`,
        method: "post",
        data,
    });
};

//修改技术需求
export const editServiceDemandApi = (data) => {
    return request({
        url: `/api/${zhpt}/demand/science/edit`,
        method: "post",
        data,
    });
};
